package main
import (
	"fmt"
	"os"
)

//  30. 错误处理
func main(){
	f, err := os.Open("/test.text")
	fmt.Println("f= ", f)
	fmt.Println("err= ", err)
	if err != nil {
		fmt.Println(err)	//open /test.text: The system cannot find the file specified.
	}
	fmt.Println(f.Name(), "opened successfully")

}
